﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using WordSmith_V1.Library.Model.EntityFrameWork;
using WordSmith_V1.ViewModel;
using WordSmith_V1.Library.Model;

namespace WordSmith_V1.Controllers
{
    public class MembersController : Controller
    {
        private WordSmithContext DB = new WordSmithContext();
        //
        // GET: /Members/

        public ActionResult Index()
        {
            return View();
        }


        public ActionResult List()
        {
            AccountSummaryViewModel viewModel = new AccountSummaryViewModel();
            List<Menu> menuLinks = new List<Menu>{ new Menu("Home","Home","Home"),new Menu("News","News","News"),new Menu("Members","Members","Members"),new Menu("Multimedia","Multimedia","Multimedia"),
                new Menu("Web Store","WebStore","WebStore"),new Menu("Start a book","Create","Book")};
            viewModel.userMenuLinks = menuLinks;

            var users = DB.Users.ToList();
            viewModel.Friends = users;
            return View(viewModel);
        }

    }
}
